<template>
    <div class="mechat-detail">
        <header>
            <div class="header">
                <div class="icon-fanhui" @click='$router.back()'></div>
                <div class="text">
                    详情
                </div>
                <!--<div class="icon-list" @click="showList">-->
                    <!--<div class="list" v-bind:class="{active:show_list}">-->
                        <!--<ul>-->
                            <!--<li>查看二维码</li>-->
                            <!--<li>查看协议</li>-->
                            <!--<li>查看产品</li>-->
                        <!--</ul>-->
                    <!--</div>-->
                <!--</div>-->

            </div>
        </header>
        <div class="content">
            <!--商户信息-->
            <div class="page-module">
                <div class="page-header">
                    {{storeDetail.retail_name}}
                </div>
                <div class="page-body">
                    <ul>
                        <li>
                            <span>商户代码:</span>
                            <span>{{storeDetail.retail_no}}</span>
                        </li>
                        <li>
                            <span>商户名称:</span>
                            <span>{{storeDetail.retail_name}}</span>
                        </li>
                        <li>
                            <span>商户类型:</span>
                            <span>{{storeDetail.retail_type}}</span>
                        </li>
                        <li>
                            <span>商户所在城市:</span>
                            <span>{{storeDetail.retail_city}}</span>
                        </li>
                        <li>
                            <span>法定代表人:</span>
                            <span>{{storeDetail.retail_law_person}}</span>
                        </li>
                        <li>
                            <span>法人身份证号码:</span>
                            <span>{{storeDetail.retail_law_person_card_no}}</span>
                        </li>
                        <li>
                            <span>主要联系人:</span>
                            <span>{{storeDetail.retail_link_name}}</span>
                        </li>
                        <li>
                            <span>主要联系人号码:</span>
                            <span>{{storeDetail.retail_link_tel}}</span>
                        </li>
                        <li>
                            <span>主要联系人邮箱:</span>
                            <span>{{storeDetail.retail_link_email}}</span>
                        </li>
                        <li>
                            <span>财务人员姓名:</span>
                            <span>{{storeDetail.retail_financial_name}}</span>
                        </li>
                        <li>
                            <span>财务人员邮箱:</span>
                            <span>{{storeDetail.retail_financial_email}}</span>
                        </li>
                        <li>
                            <span>结算账户开户行所在省市:</span>
                            <span>{{storeDetail.retail_account_bank_city}}</span>
                        </li>
                        <li>
                            <span>账号开户行:</span>
                            <span>{{storeDetail.retail_account_bank}}</span>
                        </li>
                        <li>
                            <span>账号开户名:</span>
                            <span>{{storeDetail.retail_account_name}}</span>
                        </li>
                        <li>
                            <span>账号开户支行:</span>
                            <span>{{storeDetail.retail_branch_code}}</span>
                        </li>
                        <li>
                            <span>账号开户账号:</span>
                            <span>{{storeDetail.retail_account}}</span>
                        </li>
                        <li>
                            <span>商户地址:</span>
                            <span>{{storeDetail.retail_address}}</span>
                        </li>
                        <li>
                            <span>分店数量:</span>
                            <span>{{storeDetail.retail_store_num}}</span>
                        </li>
                        <li>
                            <span>门店更新时间:</span>
                            <span>{{storeDetail.retail_update_date}}</span>
                        </li>
                        <li>
                            <span>门店激活时间:</span>
                            <span>{{storeDetail.retail_open_close_date}}</span>
                        </li>
                    </ul>
                </div>
            </div>
            <lg-preview id="lgPreviewImg"></lg-preview>
            <!--二维码-->
            <div class="code" v-if="QcodeUrl">
                <img v-preview="QcodeUrl" v-bind:src="QcodeUrl" alt="">
                <p>{{storeDetail.retail_name}}</p>
            </div>
        </div>
    </div>

</template>
<script>

    export default {
        name:'mechatDetail',
        components:{
        },
        data(){
            return {
                store_no: this.$route.params.store_no,
                show_list:false
            }
        },
        computed:{
            storeDetail () {
                return this.$store.state.merchat.storeDetail
            },
            QcodeUrl (){
                return this.$store.state.merchat.url
            }
        },
        methods:{
            showList(){
                this.show_list = !this.show_list
            }
        },
        created(){
            this.$store.dispatch({
                type:'storeDetail',
                store_no:this.store_no
            })

            this.$store.dispatch({
                type:'storeQcode',
                store_no:this.store_no
            })
        }
    }
</script>